<?php

use yii\db\Migration;

class m000004_000001_create_api extends Migration
{
    public function safeUp()
    {
        $this->createTable('{{%api}}', [
            'id' => $this->primaryKey(),
            'name' => $this->string(32)->notNull()->comment('名称'),
            'param' => $this->text()->notNull()->comment('数据'),
        ]);
    }

    public function down()
    {
        $this->dropTable('{{%api}}');
    }
}
